package br.mia.unifor.onaga.cloud.artifact;

import br.mia.unifor.onaga.cloud.artifact.script.Scriptlet;

import java.util.List;


public class Instance extends OnagaArtifact{
	private InstanceType type;
	private String name;
	private List<Scriptlet> onStartup;
	private List<Scriptlet> onShutdown;
	private List<Application> applications;
	private String publicIpAddress;
	private String privateIpAddress;


	public InstanceType getType() {
		return type;
	}

	public void setType(InstanceType type) {
		this.type = type;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getName() {
		return name;
	}


	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Instance other = (Instance) obj;
		if (getId() == null) {
			if (other.getId() != null)
				return false;
		} else if (!getId().equals(other.getId()))
			return false;
		return true;
	}

	public void setPublicIpAddress(String publicIpAddress) {
		this.publicIpAddress = publicIpAddress;
	}

	public String getPublicIpAddress() {
		return publicIpAddress;
	}

	public void setPrivateIpAddress(String privateIpAddress) {
		this.privateIpAddress = privateIpAddress;
	}

	public String getPrivateIpAddress() {
		return privateIpAddress;
	}

	public void setOnStartup(List<Scriptlet> onStartup) {
		this.onStartup = onStartup;
	}

	public List<Scriptlet> getOnStartup() {
		return onStartup;
	}

	public void setOnShutdown(List<Scriptlet> onShutdown) {
		this.onShutdown = onShutdown;
	}

	public List<Scriptlet> getOnShutdown() {
		return onShutdown;
	}

	public void setApplications(List<Application> applications) {
		this.applications = applications;
	}

	public List<Application> getApplications() {
		return applications;
	}


	
}